package com.ruoyi.crop.controller;

import com.ruoyi.crop.util.UploadMinioUtils;
import org.springframework.web.bind.annotation.CrossOrigin;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import org.springframework.web.multipart.MultipartFile;

@RestController
@CrossOrigin
@RequestMapping("upload")
public class uploadController {
    @PostMapping("uploadFile")
    public String uploadFile(MultipartFile file){
        String s = UploadMinioUtils.uploadPic(file);
        return s;
    }
}
